package com.esri.core.tasks.ags.query;

import com.esri.core.geometry.Geometry;
import com.esri.core.geometry.SpatialReference;
import com.esri.core.internal.tasks.ags.c.i;
import com.esri.core.map.TimeExtent;
import com.esri.core.tasks.SpatialRelationship;
import java.util.Map;

/* loaded from: classes.dex */
public class Query {
    i _params = new i();

    /* JADX INFO: Access modifiers changed from: package-private */
    public i getParams() {
        return this._params;
    }

    public String getWhere() {
        return this._params.e();
    }

    public void setWhere(String str) {
        this._params.a(str);
    }

    public String getText() {
        return this._params.f();
    }

    public void setText(String str) {
        this._params.b(str);
    }

    public Geometry getGeometry() {
        return this._params.p();
    }

    public void setGeometry(Geometry geometry) {
        this._params.a(geometry);
    }

    public SpatialRelationship getSpatialRelationship() {
        return this._params.h();
    }

    public void setSpatialRelationship(SpatialRelationship spatialRelationship) {
        this._params.a(spatialRelationship);
    }

    public SpatialReference getOutSpatialReference() {
        return this._params.i();
    }

    public void setOutSpatialReference(SpatialReference spatialReference) {
        this._params.b(spatialReference);
    }

    public SpatialReference getInSpatialReference() {
        return this._params.m();
    }

    public void setInSpatialReference(SpatialReference spatialReference) {
        this._params.c(spatialReference);
    }

    public void setReturnGeometry(boolean z) {
        this._params.a(z);
    }

    public boolean isReturnGeometry() {
        return this._params.j();
    }

    public void setOutFields(String[] strArr) {
        this._params.a(strArr);
    }

    public String[] getOutFields() {
        return this._params.l();
    }

    @Deprecated
    public void setObjectIds(int[] iArr) {
        this._params.a(convertToLongArray(iArr));
    }

    public void setObjectIds(long[] jArr) {
        this._params.a(jArr);
    }

    @Deprecated
    public int[] getObjectIds() {
        return convertTointArray(this._params.d());
    }

    public long[] getObjectIdsInLong() {
        return this._params.d();
    }

    private int[] convertTointArray(long[] jArr) {
        if (jArr == null || jArr.length <= 0) {
            return new int[0];
        }
        int[] iArr = new int[jArr.length];
        for (int i = 0; i < jArr.length; i++) {
            iArr[i] = (int) jArr[i];
        }
        return iArr;
    }

    private long[] convertToLongArray(int[] iArr) {
        if (iArr == null || iArr.length <= 0) {
            return new long[0];
        }
        long[] jArr = new long[iArr.length];
        for (int i = 0; i < iArr.length; i++) {
            jArr[i] = iArr[i];
        }
        return jArr;
    }

    public void setReturnIdsOnly(boolean z) {
        this._params.b(z);
    }

    public boolean isReturnIdsOnly() {
        return this._params.k();
    }

    public void setMaxAllowableOffset(double d) {
        this._params.a(d);
    }

    public double getMaxAllowableOffset() {
        return this._params.g();
    }

    public void setMaxFeatures(int i) {
        this._params.a(i);
    }

    public Map<String, OrderByFields> getOrderByFields() {
        return this._params.r();
    }

    public void setOrderByFields(Map<String, OrderByFields> map) {
        this._params.b(map);
    }

    public String[] getGroupByFieldsForStatistics() {
        return this._params.s();
    }

    public void setGroupByFieldsForStatistics(String[] strArr) {
        this._params.b(strArr);
    }

    public OutStatistics[] getOutStatistics() {
        return getOutStatistics();
    }

    public void setOutStatistics(OutStatistics[] outStatisticsArr) {
        this._params.a(outStatisticsArr);
    }

    public int getMaxFeatures() {
        return this._params.a();
    }

    public Object toInternalFormat() {
        return this._params;
    }

    public TimeExtent getTimeExtent() {
        return this._params.n();
    }

    public void setTimeExtent(TimeExtent timeExtent) {
        this._params.a(timeExtent);
    }

    public int hashCode() {
        i iVar = this._params;
        return 31 + (iVar == null ? 0 : iVar.hashCode());
    }

    public boolean equals(Object obj) {
        if (this == obj) {
            return true;
        }
        if (obj != null && getClass() == obj.getClass()) {
            Query query = (Query) obj;
            i iVar = this._params;
            if (iVar == null) {
                if (query._params != null) {
                    return false;
                }
            } else if (!iVar.equals(query._params)) {
                return false;
            }
            return true;
        }
        return false;
    }
}
